//
//  YDYFanju.m
//  DY_Bilibili
//
//  Created by 杨德勇 on 2016/9/29.
//  Copyright © 2016年 杨德勇. All rights reserved.
//

#import "YDYFanju.h"

@implementation YDYFanju

-(instancetype)initWithDict:(NSDictionary *)dict{
    
    [self setValuesForKeysWithDictionary:dict];
    return self;
}
+(instancetype)ydyFanjuWithDict:(NSDictionary *)dict{
    return [[self alloc]initWithDict:dict];
    
}
-(void)setValue:(id)value forUndefinedKey:(NSString *)key{
    
}

-(void)setValue:(id)value forKey:(NSString *)key{
    if ([key isEqualToString:@"description"]) {
        _description_ = value;
    }
    
    if ([key isEqualToString:@"typeid"]) {
        _type = [value intValue];
    }
    
    if ([key isEqualToString:@"typename"]) {
        _typename_ = value;
    }
    
    [super setValue:value forKey:key];
    
}
@end
